package com.vinaprime.primeschedule.presentation;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;

public class BootCompletedIntentReceiver extends BroadcastReceiver {
	
	private Context myContext;
	
	@Override  
	 public void onReceive(Context context, Intent intent) {  
	  if ("android.intent.action.BOOT_COMPLETED".equals(intent.getAction())) {  
		  myContext = context;
		  
		  new Thread(new Runnable() {
			
			public void run() {
				Intent pushIntent = new Intent(myContext, PrimeScheduleService.class);  
				myContext.startService(pushIntent);
			}
		}).start();
		  
	  }  
	 }  
}
